package com.itheima.service.impl;

import com.itheima.dao.BookDao;
import com.itheima.service.BookService;

import java.util.Arrays;
import java.util.List;
import java.util.Map;

public class BookServiceImpl implements BookService {
    //5.删除业务层中使用new的方式创建的dao对象
    private BookDao bookDao;

    private List list;
    private int []array;
    private Map<String,String>map;

    public void setList(List list) {
        this.list = list;
    }

    public void setArray(int[] array) {
        this.array = array;
    }

    public void setMap(Map<String, String> map) {
        this.map = map;
    }


    //6.提供对应的set方法
    public void setBookDao(BookDao bookDao) {
        this.bookDao = bookDao;
    }
    public void save() {
        System.out.println("book service save ...");
        System.out.println("数组"+Arrays.toString(array));
        System.out.println("集合"+list);
        System.out.println("map"+map);
        bookDao.save();
    }

}
